home *** CD-ROM | disk | FTP | other *** search
/ Mac Magazin/MacEasy 19 / Mac Magazin and MacEasy Magazine CD - Issue 19.iso / Online / HttpServerƒ / •Mac_Classes / TContext.cp < prev    next >
Text File  |  1996-01-05  |  2KB  |  49 lines

  1. //    TContext.cp - Macintosh Task Context class object
  2. // 
  3. // Apple Macintosh Developer Technical Support
  4. // Written by:  Vinne Moscaritolo
  5. //
  6. //  Copyright (work in progress)  Apple Computer, Inc All rights reserved.
  7. //
  8. // You may incorporate this sample code into your applications without
  9. // restriction, though the sample code has been provided "AS IS" and the
  10. // responsibility for its operation is 100% yours.  However, what you are
  11. // not permitted to do is to redistribute the source as "DSC Sample Code"
  12. // after having made changes. If you're going to re-distribute the source,
  13. // we require that you make it clear in the source that the code was
  14. // descended from Apple Sample Code, but that you've made changes.
  15. // 
  16.  
  17. #include "TContext.h"
  18.  
  19. // CodeWarrior Exception handling
  20.  
  21. TContext::TContext()
  22. {
  23. //    __new_exception_state(&fExceptionState, fCatchBuffer, sizeof(fCatchBuffer));
  24. }
  25.  
  26. // ---------------------------------------------------------------------------
  27. //     TContext:Save
  28. // ---------------------------------------------------------------------------
  29. // Save Macintosh Context
  30.  
  31. void TContext::Save()
  32. {
  33.     // save exception-handling context
  34. //    __switch_exception_state(&fExceptionState, &fExceptionState);
  35. }
  36.  
  37. // ---------------------------------------------------------------------------
  38. //     TContext:Restore
  39. // ---------------------------------------------------------------------------
  40. // Restore Macintosh Context
  41.  
  42. void TContext::Restore()
  43. {
  44.     ExceptionState    gone;
  45.  
  46.     // restore exception-handling context
  47. //    __switch_exception_state(&fExceptionState, &gone);
  48. }
  49.